package com.linkhub.oms.dao.mpservice.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.linkhub.oms.common.enums.mp.DataStatusEnum;
import com.linkhub.oms.dao.mapper.CountryTaxEntityMapper;
import com.linkhub.oms.dao.mpservice.ICountryTaxService;
import com.linkhub.oms.entity.CountryTaxEntity;
import com.linkhub.oms.entity.OrderEntity;
import org.springframework.stereotype.Service;

/**
 * @author Redball
 * @version 1.0.0
 * @Description CountryTaxServiceImpl
 * @createTime 2024/7/5 上午1:09
 */
@Service
public class CountryTaxServiceImpl extends ServiceImpl<CountryTaxEntityMapper, CountryTaxEntity> implements ICountryTaxService {

    @Override
    public CountryTaxEntity getByCountryCode(String countryCode) {
        return lambdaQuery()
                .eq(CountryTaxEntity::getCountryCode, countryCode)
                .eq(CountryTaxEntity::getDataStatus, DataStatusEnum.ENABLE)
                .one();
    }
}
